package cz.uvn.orthopedy.server.jdo;

import javax.jdo.JDOHelper;
import javax.jdo.PersistenceManagerFactory;

public final class PMF {

	private static PersistenceManagerFactory instance;

	private PMF() {
	}

	public static synchronized PersistenceManagerFactory get() {
		if (instance == null) {
			instance = JDOHelper.getPersistenceManagerFactory("transactions-optional"); 
		}
		return instance;
	}

	public static boolean isPersistent(Object object) {
		return JDOHelper.isPersistent(object);
	}
}
